<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="/struts-tags" prefix="s" %>


<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'showone.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>
  
  <body>
  <center>

     <h1>user infomation</h1>
     <s:form action="updateUser">
   <table width="200px">
   
   <tr>
    
    <td colspan="2">
    <s:hidden name="user.id" value="%{user.id}"></s:hidden>
    </td>
    </tr>
   
    <tr>
    
    <td colspan="2">
    <s:textfield name="user.firstname" value="%{user.firstname}" label="firstname"></s:textfield>
    </td>
    </tr>
   
    <tr>
    
    <td colspan="2">
    <s:textfield name="user.lastname" value="%{user.lastname}" label="lastname"></s:textfield>
    </td>
    </tr>
    
     <tr>
    
    <td colspan="2">
    <s:textfield name="user.age" value="%{user.age}" label="age"></s:textfield>
    </td>
    </tr>
   <tr>
   
   <td><s:submit value="更新"></s:submit>
   
   </td>
   <td><input type="button" value="取消" onclick="history.back(-1);"  ></td></tr>
   
   </table>
   
   </s:form>
   
   
   
   </center>
  </body>
</html>
